package com.n9.qq.android.login.tlv;

import com.n9.qq.util.Util;

/**
 * 0x0018的数据片段
 * @author ice
 * @since 2019/2/11 10:24
 */
public class Tlv0018 extends BaseTlv {
    private int len = 22;
    private int i = 1;
    private int j = 1536;
    public Tlv0018() {
        this.cmd = 0x0018;
    }

    /**
     *
     * @param paramLong1    固定0x00000010
     * @param paramInt1     固定0x00000000
     * @param qqUin         qq号
     * @param paramInt2     固定0x00000000
     * @return
     */
    public byte[] getData(long paramLong1, int paramInt1, long qqUin, int paramInt2) {
        byte[] arrayOfByte = new byte[this.len];
        Util.int16_to_buf(arrayOfByte, 0, this.i);
        Util.int32_to_buf(arrayOfByte, 2, this.j);
        Util.int32_to_buf(arrayOfByte, 6, (int)paramLong1);
        Util.int32_to_buf(arrayOfByte, 10, paramInt1);
        Util.int32_to_buf(arrayOfByte, 14, (int)qqUin);
        Util.int16_to_buf(arrayOfByte, 18, paramInt2);
        Util.int16_to_buf(arrayOfByte, 20, 0);

        return this.getBufData(arrayOfByte);
    }
}
